#{extends 'main.html' /} #{set title:'Home' /}#{ifnot topics}

<p>No Topics</p>

#{/ifnot}
<!-- Ebrahim Zidan -->

<script>
	function passActionItem(box, topicId,actionItemId) {
	$.post('@{ActionPlanController.addTopic(topicId,actionItemId)}')
		var elm = document.getElementById(topicId)
		elm.style.display = "none"
			$('#one').jGrowl('Related')

		}
		  
	
</script>
<ul>
	#{list items:topics, as:'Topic'}

	<DIV ID=${Topic.id}>
		<li>Title : ${Topic.title}</li>
		<li>Description : ${Topic.description}</li>
		<li>Views : ${Topic.numberOfViews}</li> <input type="button"
			value="Relate"
			onclick="javascript:passActionItem(this,${Topic.id},${actionItemId})" />
	</DIV>

	<br> #{/list}

</ul>
<input type="button" onClick="history.back();" value="<-- Back">